Skip to content

test(api): bring the tool node and extractor helper tests under strict pyrefly - #46341

Open
MindOfqc wants to merge 12 commits into
langgenius:mainfrom
MindOfqc:test/pyrefly-tool-node-and-extractor-helpers
Open

MindOfqc wants to merge 12 commits into
langgenius:mainfrom
MindOfqc:test/pyrefly-tool-node-and-extractor-helpers

Conversation

@MindOfqc

Copy link
Copy Markdown
Contributor

Why

Two test modules are still listed in project-excludes, so they are never checked under strict pyrefly:

  • api/tests/e2e_tests/contracts/core/workflow/nodes/tool/test_tool_node.py
  • api/tests/unit_tests/core/rag/extractor/test_helpers.py

Summary

Brings both under strict checking and removes their entries from project-excludes (208 → 206 entries).

Thirty-two diagnostics are cleared with real types — return annotations on the test methods, parameter annotations on the node/document factories, and typed stand-ins where an empty container or a SimpleNamespace left the element type unknown. Assertions and the exercised paths are unchanged.

No # pyrefly: ignore, no # type: ignore, no typing.cast, no typing.Any.

Verification

  • Strict pyrefly project check (api/tests/unit_tests, pyrefly 1.5.0-dev.1 with the repo venv interpreter): ERROR 29 with all 29 being the pre-existing missing-import noise. WARN 0. Target files residual 0.
  • pytest on both files → 11 passed.
  • ruff check and ruff format --check clean.

…t pyrefly

Annotate the workflow tool node test and the rag extractor helper test so both
pass the strict pyrefly project check, then drop their entries from
project-excludes.

Thirty-two diagnostics are cleared, all with real types: return annotations on
the test methods, parameter annotations on the node and document factories, and
typed stand-ins where an empty container or a `SimpleNamespace` left the element
type unknown. Assertions and the exercised paths are unchanged.
No ignores, no casts, no typing.Any.
@github-actions github-actions Bot added the size:M This PR changes 30-99 lines, ignoring generated files. label Nov 14, 2026
@github-actions

github-actions Bot commented Nov 14, 2026 •

Copy link
Copy Markdown
Contributor

Pyrefly Diff

base → PR
--- /tmp/pyrefly_base.txt	2026-11-18 10:48:58.776697525 +0000
+++ /tmp/pyrefly_pr.txt	2026-11-18 10:48:39.772579436 +0000
@@ -1672,10 +1672,6 @@
    --> tests/e2e_tests/contracts/core/workflow/nodes/test_if_else.py:388:19
 ERROR Argument `dict[str, list[dict[str, list[dict[str, list[str] | str]] | str]] | str]` is not assignable to parameter `node_data` with type `IfElseNodeData | dict[str, object]` in function `_build_if_else_node` [bad-argument-type]
    --> tests/e2e_tests/contracts/core/workflow/nodes/test_if_else.py:453:19
-ERROR Argument `_StubToolRuntime` is not assignable to parameter `runtime` with type `ToolNodeRuntimeProtocol` in function `graphon.nodes.tool.tool_node.ToolNode.__init__` [bad-argument-type]
-   --> tests/e2e_tests/contracts/core/workflow/nodes/tool/test_tool_node.py:112:17
-ERROR Argument `Iterator[ToolRuntimeMessage]` is not assignable to parameter `messages` with type `Generator[ToolRuntimeMessage]` in function `graphon.nodes.tool.tool_node.ToolNode._transform_message` [bad-argument-type]
-   --> tests/e2e_tests/contracts/core/workflow/nodes/tool/test_tool_node.py:128:18
 ERROR Argument `list[ParagraphInputConfig]` is not assignable to parameter `inputs` with type `list[FormInputConfig]` in function `tests.helpers.unit.libs._human_input.support.FormService.create_form` [bad-argument-type]
    --> tests/e2e_tests/contracts/libs/_human_input/test_form_service.py:311:34
 ERROR `-` is not supported between `None` and `datetime` [unsupported-operation]
@@ -4870,67 +4866,67 @@
 ERROR `SimpleNamespace` is not assignable to attribute `runtime_state` with type `RuntimeState` [bad-assignment]
     --> tests/unit_tests/core/workflow/test_node_factory.py:1504:37
 ERROR Object of class `object` has no attribute `parent_trace_context` [missing-attribute]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:1184:16
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:1185:16
 ERROR Object of class `object` has no attribute `trace_session_id` [missing-attribute]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:1225:16
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:1226:16
 ERROR Argument `object` is not assignable to parameter `message` with type `ToolInvokeMessage.BlobChunkMessage | ToolInvokeMessage.BlobMessage | ToolInvokeMessage.FileMessage | ToolInvokeMessage.JsonMessage | ToolInvokeMessage.LogMessage | ToolInvokeMessage.RetrieverResourceMessage | ToolInvokeMessage.TextMessage | ToolInvokeMessage.VariableMessage | None` in function `core.workflow.node_runtime.DifyToolNodeRuntime._convert_message_payload` [bad-argument-type]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:1318:52
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:1319:52
 ERROR Argument `object` is not assignable to parameter `message` with type `ToolInvokeMessage.BlobChunkMessage | ToolInvokeMessage.BlobMessage | ToolInvokeMessage.FileMessage | ToolInvokeMessage.JsonMessage | ToolInvokeMessage.LogMessage | ToolInvokeMessage.RetrieverResourceMessage | ToolInvokeMessage.TextMessage | ToolInvokeMessage.VariableMessage | None` in function `core.workflow.node_runtime.DifyToolNodeRuntime._convert_message_payload` [bad-argument-type]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:1325:46
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:1326:46
 ERROR `object | None` is not assignable to attribute `model_runtime` with type `LLMModelRuntime` [bad-assignment]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:1444:30
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:1445:30
 ERROR Argument `list[FromClause]` is not assignable to parameter `tables` with type `Sequence[Table] | None` in function `sqlalchemy.sql.schema.MetaData.create_all` [bad-argument-type]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:1508:60
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:1509:60
 ERROR Object of class `ExternalRecipient` has no attribute `reference_id` [missing-attribute]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:1533:16
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:1534:16
 ERROR Argument `object` is not assignable to parameter `method` with type `EmailDeliveryMethod | InstantMessageDeliveryMethod | InteractiveSurfaceDeliveryMethod` in function `core.workflow.node_runtime.apply_dify_debug_email_recipient` [bad-argument-type]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:1548:49
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:1549:49
 ERROR Argument `_ModelInstanceStub` is not assignable to parameter `model_instance` with type `ModelInstance` in function `core.workflow.node_runtime.DifyPreparedLLM.__init__` [bad-argument-type]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:1571:36
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:1569:36
 ERROR Object of class `FunctionType` has no attribute `assert_called_once_with` [missing-attribute]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:1590:9
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:1588:9
 ERROR Argument `_ModelInstanceStub` is not assignable to parameter `model_instance` with type `ModelInstance` in function `core.workflow.node_runtime.DifyPreparedLLM.__init__` [bad-argument-type]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:1604:36
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:1602:36
 ERROR Argument `_ModelInstanceStub` is not assignable to parameter `model_instance` with type `ModelInstance` in function `core.workflow.node_runtime.DifyPreparedLLM.__init__` [bad-argument-type]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:1612:36
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:1610:36
 ERROR Argument `SimpleNamespace` is not assignable to parameter `model_instance` with type `ModelInstance` in function `core.workflow.node_runtime.DifyPreparedLLM.__init__` [bad-argument-type]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:1639:36
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:1637:36
 ERROR Argument `_ModelInstanceStub` is not assignable to parameter `model_instance` with type `ModelInstance` in function `core.workflow.node_runtime.DifyPreparedPollingLLM.__init__` [bad-argument-type]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:1664:43
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:1662:43
 ERROR Object of class `FunctionType` has no attribute `return_value` [missing-attribute]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:1729:9
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:1727:9
 ERROR Object of class `FunctionType` has no attribute `return_value` [missing-attribute]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:1767:9
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:1765:9
 ERROR Object of class `FunctionType` has no attribute `side_effect` [missing-attribute]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:1804:9
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:1802:9
 ERROR Object of class `FunctionType` has no attribute `call_count` [missing-attribute]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:1818:16
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:1816:16
 ERROR Object of class `FunctionType` has no attribute `return_value` [missing-attribute]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:1835:9
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:1833:9
 ERROR Object of class `FunctionType` has no attribute `return_value` [missing-attribute]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:1865:9
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:1863:9
 ERROR Argument `_ModelInstanceStub` is not assignable to parameter `model_instance` with type `ModelInstance` in function `core.workflow.node_runtime.DifyPreparedPollingLLM.__init__` [bad-argument-type]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:1902:43
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:1900:43
 ERROR Argument `Literal['chat']` is not assignable to parameter `model_mode` with type `LLMMode` in function `core.workflow.node_runtime.DifyPromptMessageSerializer.serialize` [bad-argument-type]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:1919:24
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:1917:24
 ERROR Object of class `NoneType` has no attribute `storage_key` [missing-attribute]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:1948:16
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:1946:16
 ERROR Argument `object` is not assignable to parameter `variable_pool` with type `VariablePool | None` in function `core.workflow.node_runtime.DifyToolNodeRuntime.get_runtime` [bad-argument-type]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:2182:27
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:2180:27
 ERROR Object of class `object` has no attribute `tool` [missing-attribute]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:2186:16
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:2184:16
 ERROR Object of class `object` has no attribute `parent_trace_context` [missing-attribute]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:2187:16
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:2185:16
 ERROR Object of class `object` has no attribute `trace_session_id` [missing-attribute]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:2210:9
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:2208:9
 ERROR Argument `object` is not assignable to parameter `variable_pool` with type `VariablePool | None` in function `core.workflow.node_runtime.DifyToolNodeRuntime.get_runtime` [bad-argument-type]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:2227:27
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:2225:27
 ERROR Object of class `object` has no attribute `trace_session_id` [missing-attribute]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:2231:16
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:2229:16
 ERROR Argument `object` is not assignable to parameter `variable_pool` with type `VariablePool | None` in function `core.workflow.node_runtime.DifyToolNodeRuntime.get_runtime` [bad-argument-type]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:2259:27
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:2257:27
 ERROR Object of class `object` has no attribute `tool` [missing-attribute]
-    --> tests/unit_tests/core/workflow/test_node_runtime.py:2262:16
+    --> tests/unit_tests/core/workflow/test_node_runtime.py:2260:16
 WARN Cannot instantiate `BaseNodeData` because it directly extends `ABC` or uses `ABCMeta` [direct-abstract-base-instantiation]
     --> tests/unit_tests/core/workflow/test_workflow_entry.py:1010:50
 ERROR `in` is not supported between `Literal['Maximum execution steps exceeded: 3 > 2']` and `None` [not-iterable]

@github-actions

github-actions Bot commented Nov 14, 2026 •

Copy link
Copy Markdown
Contributor

Pyrefly Type Coverage

Metric Base PR Delta
Type coverage 86.86% 86.87% +0.01%
Strict coverage 86.52% 86.53% +0.01%
Typed symbols 95,376 95,427 +51
Untyped symbols 14,489 14,479 -10
Modules 4630 4630 0

@codecov

codecov Bot commented Nov 14, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 90.39%. Comparing base (ab7bbed) to head (1875d44).
⚠️ Report is 104 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main   #46341      +/-   ##
==========================================
- Coverage   90.41%   90.39%   -0.02%     
==========================================
  Files        6334     6380      +46     
  Lines      396673   404727    +8054     
  Branches    79711    80909    +1198     
==========================================
+ Hits       358637   365846    +7209     
- Misses      31928    32478     +550     
- Partials     6108     6403     +295     
Flag Coverage Δ
api 90.08% <100.00%> (-0.02%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

# Conflicts:
#	api/tests/unit_tests/pyrefly.toml

stream.read = Mock(side_effect=tracked_read)
reads.append(stream.read)
reader = Mock(side_effect=tracked_read)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

real class ?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Addressed: detect_file_encodings now accepts the production FileSampleReader Protocol with the real read_file_sample as its default. The test injects a recording reader that opens the actual temporary file and verifies the sample bounds.

self, monkeypatch: pytest.MonkeyPatch, tmp_path: Path, no_match: bool
):
) -> None:
class FakeResult:

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

.


def test_detect_file_encodings_timeout(self, monkeypatch: pytest.MonkeyPatch):
def test_detect_file_encodings_timeout(self, monkeypatch: pytest.MonkeyPatch) -> None:
class FakeFuture:

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

.

@asukaminato0721 asukaminato0721 self-assigned this Nov 15, 2026
…e-and-extractor-helpers

Resolve the pyrefly.toml excludes conflict by dropping all four
graduated entries: this branch graduates test_helpers.py and
tool/test_tool_node.py, upstream graduated test_markdown_extractor.py
and test_list_operator.py. No file stays excluded on either side.
…yrefly-tool-node-and-extractor-helpers

Resolve the `project-excludes` conflict: upstream graduated
`core/workflow/test_node_runtime.py` in another PR, so that entry stays
excluded, while this branch's own
`../e2e_tests/contracts/core/workflow/nodes/tool/test_tool_node.py`
stays graduated here.

@asukaminato0721 asukaminato0721 left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

4 inline suggestions at 8e94ecac5c, each from a rule learned from earlier reviews in this repository. Reply on a comment if it is wrong.

dify-codereview

@github-actions github-actions Bot added size:L This PR changes 100-499 lines, ignoring generated files. and removed size:M This PR changes 30-99 lines, ignoring generated files. labels Nov 16, 2026

@asukaminato0721 asukaminato0721 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

4 inline suggestions at 34dd9e7fd8, each from a rule learned from earlier reviews in this repository. Reply on a comment if it is wrong.

dify-codereview

return False

def submit(self, fn, file_path):
def submit[**P](

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This forwards to another callable, so use a ParamSpec: def f[**P](*args: P.args, **kwargs: P.kwargs), and the signature follows the callable it wraps.

dify-codereview · precise-types (paramspec) Learned from an earlier review. Reply here if this is wrong.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Addressed: the forwarding method now uses the wrapped callable's ParamSpec via submit[**P](..., *args: P.args, **kwargs: P.kwargs).

The tool-file protocol and the adapter that implements it both returned a
bare Generator, which says nothing about what the stream yields. pyrefly
cannot infer the three generic parameters and rejects the annotation.

The stream is read chunk by chunk as bytes everywhere it is consumed, which
matches the storage backends: aliyun_oss_storage.load_stream reads 4096-byte
chunks from the object and yields them directly. Spell that out.

@asukaminato0721 asukaminato0721 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

1 inline suggestion at 33628effe8, from a rule learned from earlier reviews in this repository. Reply on the comment if it is wrong. 4 earlier suggestions are still open.

dify-codereview

asukaminato0721

This comment was marked as outdated.

@asukaminato0721 asukaminato0721 added the waiting-for-author dify-codereview: the author has suggestions, a conflict, failing CI or unresolved threads to address label Nov 16, 2026
@MindOfqc

Copy link
Copy Markdown
Contributor Author

The WebKit Browser Smoke failure is infrastructure, not a regression from this PR. The job log (133288802847) shows Web build download failed (1). See .../cucumber-web-build.log — the shared web build artifact failed to download before any test ran. This PR changes only api/core/rag/extractor/helpers.py, api/core/workflow/node_runtime.py and their tests (zero web/ files). main HEAD's Web E2E is currently green. A re-run should clear it.

The tool-runtime stub returned the incoming mapping whenever no File was
injected, so the contract test accepted a value the production runtime never
produces. graphon appends the result straight to the node file output, and the
FileReferenceFactoryProtocol requires a File.

Validate the mapping with the production ToolFileMapping shape and build the
File through the real factory against a persisted ToolFile row, then assert
every field against that row. Add two negative cases: a tool-file row owned by
another tenant must not resolve, and a mapping without transfer_method must be
rejected before any lookup.

Also give DifyFileReferenceFactory.build_from_mapping and the runtime's
build_file_reference their real File return type, and export the mapping
shapes from factories.file_factory so tests import them instead of restating
them.

Verified: 6 passed in the contract suite, 124 passed across the file factory
and extractor helper suites, pyrefly 0 diagnostics, ruff clean, all eight
guards clean. Five mutations (storage key, remote url, tenant filter,
hand-built File, skipped validation) were each caught by the new assertions.

@asukaminato0721 asukaminato0721 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

1 inline suggestion at de8770b8b3, from a rule learned from earlier reviews in this repository. Reply on the comment if it is wrong. 6 review threads are still unresolved.

dify-codereview

*,
tool_runtime: ToolRuntimeHandle,
tool_parameters: dict[str, Any],
tool_parameters: Mapping[str, Any],

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Parse, don't validate (https://lexi-lambda.github.io/blog/2019/11/05/parse-don-t-validate/): model this data once at the boundary as a pydantic model / dataclass / TypedDict (Model.model_validate(raw)), and pass the typed value on, instead of passing dicts around and re-checking keys and types where they are used. In a test, don't build this as an ad hoc dict[str, object]: define the shape (TypedDict / model) in the production code and import it here.

dify-codereview · parse-dont-validate Learned from an earlier review. Reply here if this is wrong.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Addressed at the production boundary: valid cases use the imported production mapping types, and DifyFileReferenceFactory parses the incoming mapping with TypeAdapter(FileMapping). The raw dict in this negative case is intentionally malformed to assert rejection before the builder runs.

@asukaminato0721 asukaminato0721 added waiting-for-author dify-codereview: the author has suggestions, a conflict, failing CI or unresolved threads to address and removed waiting-for-author dify-codereview: the author has suggestions, a conflict, failing CI or unresolved threads to address labels Nov 17, 2026
@github-actions github-actions Bot added size:XL This PR changes 500-999 lines, ignoring generated files. and removed size:L This PR changes 100-499 lines, ignoring generated files. labels Nov 18, 2026

@asukaminato0721 asukaminato0721 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

3 inline suggestions at 680fdda731, each from a rule learned from earlier reviews in this repository. Reply on a comment if it is wrong. 7 review threads are still unresolved.

dify-codereview

@asukaminato0721 asukaminato0721 added waiting-for-author dify-codereview: the author has suggestions, a conflict, failing CI or unresolved threads to address and removed waiting-for-author dify-codereview: the author has suggestions, a conflict, failing CI or unresolved threads to address labels Nov 18, 2026
@asukaminato0721 asukaminato0721 added waiting-for-author dify-codereview: the author has suggestions, a conflict, failing CI or unresolved threads to address and removed waiting-for-author dify-codereview: the author has suggestions, a conflict, failing CI or unresolved threads to address labels Nov 18, 2026

@asukaminato0721 asukaminato0721 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

1 inline suggestion at cb4cccd401, from a rule learned from earlier reviews in this repository. Reply on the comment if it is wrong. 6 review threads are still unresolved.

dify-codereview

@asukaminato0721 asukaminato0721 added waiting-for-author dify-codereview: the author has suggestions, a conflict, failing CI or unresolved threads to address and removed waiting-for-author dify-codereview: the author has suggestions, a conflict, failing CI or unresolved threads to address labels Nov 18, 2026
@asukaminato0721 asukaminato0721 added waiting-for-author dify-codereview: the author has suggestions, a conflict, failing CI or unresolved threads to address and removed waiting-for-author dify-codereview: the author has suggestions, a conflict, failing CI or unresolved threads to address labels Nov 18, 2026
@asukaminato0721 asukaminato0721 added waiting-for-author dify-codereview: the author has suggestions, a conflict, failing CI or unresolved threads to address and removed waiting-for-author dify-codereview: the author has suggestions, a conflict, failing CI or unresolved threads to address labels Nov 18, 2026

@asukaminato0721 asukaminato0721 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider splitting this into smaller pull requests: it adds 263 lines of non-test code, past about 150. Split it by feature: each pull request carries one functional change together with its tests, so each feature stands on its own and can be reviewed, merged and reverted independently. A rule of thumb, not a requirement. Size counts added non-test lines; tests, lock files and snapshots do not count.

dify-codereview

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:XL This PR changes 500-999 lines, ignoring generated files. waiting-for-author dify-codereview: the author has suggestions, a conflict, failing CI or unresolved threads to address

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants